package com.xiaoyu.crypto;

import java.security.KeyPair;

import javax.crypto.SecretKey;

public class AESCryptoDemo {
	
	
	public static void main(String[] args) {
		//获取相应的对称密钥和非对称密钥对
		
		//生成对称加密的密钥
		SecretKey sKey = Crypto.generateKey();
		KeyPair kp = Crypto.generateKeyPair();
		
		
		byte[] file = AESController.readFileByte();
		
		AESController.saveFile(file,sKey,kp.getPublic());
		AESController.readCryptoedFile(kp.getPrivate());
	}
}
